package com.example.mybatis_mytest.service.imp;

import com.example.mybatis_mytest.bean.QueryParam;
import com.example.mybatis_mytest.bean.Student;
import com.example.mybatis_mytest.bean.vo.StudentVo;
import com.example.mybatis_mytest.mapper.StudentMpper;
import com.example.mybatis_mytest.service.StudentService;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Service
public class StudentServiceIpl implements StudentService {
    @Autowired
    private StudentMpper studentMpper;


    @Override
    public Student selectStudentById(Integer id) {
        Student student= studentMpper.selectStudentById(id);
        return student;
    }

    @Override
    public List<StudentVo> selectMultiParam(String name, Integer age) {
        List<StudentVo> studentVoList=studentMpper.selectMultiParam( name,  age);
        return studentVoList;
    }

    @Override
    public List<Student> selectMultiObject(QueryParam param) {
        return null;
    }

    @Override
    public Student selectMultiStudent(String username,String password) {
        Student student1=studentMpper.selectMultiStudent(username,password);
        return student1;
    }

    @Override
    public Student selectMultiStudent2(Student student) {
        Student student1=studentMpper.selectMultiStudent2( student);
        return student1;
    }

    @Override
    public List<Student> selectMultiPosition(String name, Integer age) {
        return null;
    }

    @Override
    public StudentVo selectMultiByMap(Map<String, Object> map) {

        StudentVo students=studentMpper.selectMultByMap(map);
        return students;
    }

    @Override
    public List<Student> selectUse$(String name) {
        return null;
    }

    @Override
    public List<Student> selectUse$Order(String colName) {
        return null;
    }

    @Override
    public List<StudentVo> getStudentInfo() {
        return studentMpper.getStudentInfo();
    }
}
